package demo2;

abstract class Shape {
    public abstract void draw();
}
class Cycle extends Shape {
    public void draw() {
        System.out.println("⚪");
    }
}
class Rect extends Shape {
    public void draw() {
        System.out.println("⬜");
    }
}

public class Test {
    public static void drawMap(Shape shpae){
        shpae.draw();
    }
    public static void main(String[]args) {
        Shape[] shpaes = {new Cycle(),new Rect()};
        for(Shape shape:shpaes) {
            drawMap(shape);
        }
    }
}
